import 'package:fluro/fluro.dart';
import 'package:flutter/material.dart';
import 'package:flutter_base/routes/Home.dart';
import 'package:flutter_base/utils/route/BaseRouter.dart';
import 'package:flutter_base/utils/route/Interceptor.dart';

void main() {
  runApp(MyApp());
}

class MyApp extends StatelessWidget {
  MyApp({super.key}) {
    BaseRouter.setRouter(FluroRouter());
    BaseRouter.registerConfigureRoutes(BaseRouter.getRouter());
  }

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      initialRoute: HomeRouter.homePage,
      onGenerateRoute: BaseRouter.getRouter().generator,
      navigatorObservers: [Interceptor()],
    );
  }
}
